//package com.sky.module.system.role.service;
//
//import com.baomidou.mybatisplus.core.mapper.BaseMapper;
//import com.sky.module.suppot.datatrace.util.ContentUtil;
//import com.sky.module.system.datatrace.dao.DataTraceMapper;
//import com.sky.module.system.user.domain.entity.User;
//import com.sky.module.system.utils.RequestInfoUtils;
//import org.springframework.beans.factory.annotation.Autowired;
//
//import java.time.LocalDateTime;
//import java.util.Map;
//import java.util.function.Consumer;
//
///**
// * @author
// * @date 2023/3/9 1:17
// **/
//public class ConsumerTest {
//    private Consumer<DataTraceMapper> consumer;
//
//    @Autowired
//    private DataTraceMapper  dataTraceMapper;
//
//    public ConsumerTest(Consumer<DataTraceMapper> consumer) {
//        this.consumer = consumer;
//    }
//
//    public void log() {
////        final String tableName = ContentUtil.getTableName(role);
////        final Map<String, String> content = ContentUtil.getContent(oldRole, role);
////        String oldStr = content.get("oldStr");
////        String newStr = content.get("newStr");
////        User user = RequestInfoUtils.getUser();
////        String userAgent = RequestInfoUtils.getUserAgent();
////        final String ip = RequestInfoUtils.getIP();
////        final LocalDateTime now = LocalDateTime.now();
//        consumer.accept(dataTraceMapper);
//    }
//
//}
